
package com.macro.mall.service;

import com.macro.mall.common.api.CommonPage;
import com.macro.mall.common.api.CommonResult;
import com.macro.mall.dto.UmsWithdrawalApplyDto;
import com.macro.mall.model.UmsWithdrawalApply;

import java.math.BigDecimal;
import java.text.ParseException;

public interface UmsWithdrawalApplyService {
    /**
     * 获取当前用户的分销商提现列表
     * @Date 2020年9月16日
     * @author zhouboyu
     * @param userName
     * @param queryParam
     * @param pageNum
     * @param pageSize
     * @return
     */
    CommonResult<CommonPage<UmsWithdrawalApply>> getMemberWithdrawalList(String userName, UmsWithdrawalApplyDto queryParam, Integer pageNum, Integer pageSize) throws ParseException;

    /**
     * 同意提现申请，拒绝提现申请
     * @param userName
     * @param id
     * @param type
     *          0为同意提现，1为拒绝提现
     * @param reason
     *
     * @return
     */
    CommonResult agreeOrRefuse(String userName, Long id, Integer type, String reason,String ip);

    /**
     * 获取店铺提现记录列表
     * @param currentUserName
     * @param umsWithdrawalApplyDto
     * @return
     */
    CommonResult getStoreApplyList(String currentUserName, UmsWithdrawalApplyDto umsWithdrawalApplyDto) throws ParseException;

    /**
     * 查询店铺佣金总额，已结算，已提现，可提现金额
     * @param currentUserName
     * @return
     */
    CommonResult getStoreMx(String currentUserName);

    /**
     * 平台审核店铺提现申请
     * @param userName
     * @param id
     * @param type
     *          0为同意提现，1为拒绝提现
     * @param reason
     *
     * @return
     */
    CommonResult audit(String userName, Long id, Integer type, String reason,String ip);

    /**
     * 新增店铺提现申请
     * @param currentName
     * @param price
     * @return
     */
    CommonResult add(String currentName, BigDecimal price);
}
